#include"uthash.h"
#include<stdio.h>
#include<stdlib.h>
#ifndef USE_HASH_
#define USE_HASH_
#define PROTOCOL_VER 4

#if PROTOCOL_VER== 4

typedef struct
{
u_int32_t saddr;
u_int32_t daddr;
u_int16_t source_port;
u_int16_t dest_port;
u_int8_t protocol;
}record_key_t;



#elif PROTOCOL_VER== 6
typedef struct
{
u_int64_t saddr;
u_int64_t daddr;
u_int16_t source_port;
u_int16_t dest_port;
u_int8_t protocol;
}record_key_t;
#endif

typedef struct record_node
{
record_key_t key;
u_int8_t dispatch_id;
unsigned long count;

struct record_node *next;
UT_hash_handle hh;
}record_t;

#endif
